package su.samcom.calc.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import su.samcom.calc.model.dao.PropertyDao;
import su.samcom.calc.model.entity.Property;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * User: Владислав
 * Date: 17.11.13
 * Time: 5:15
 * To change this template use File | Settings | File Templates.
 */
@Service
@Transactional
public class PropertyServiceImpl implements PropertyService {

    @Autowired
    PropertyDao propertyDao;

    @Override
    public List<Property> getAll() {
        return propertyDao.getAll();
    }

    @Override
    public Property getProperty(String key) {
        return propertyDao.getProperty(key);
    }

    @Override
    public void initDatabase() {
        propertyDao.initDatabase();
    }
}
